﻿using System.ComponentModel.DataAnnotations;

namespace OpenAdmin.Core.Models;

public class EntityBase<TDbContextLocator1> : Entity<int, TDbContextLocator1>, ISoftDelete
    where TDbContextLocator1 : class, IDbContextLocator
{
    public EntityBase()
    {
        IsDeleted = false;
        CreateTime = DateTime.Now;
    }

    /// <summary>
    /// 软删除
    /// </summary>
    public bool IsDeleted { get; set; }

    /// <summary>
    /// 备注
    /// </summary>
    [MaxLength(512)]
    public virtual string Remark { get; set; }
}
